<?php

namespace Erp\ErpBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Erp\ErpBundle\Entity\Classe
 *
 * @ORM\Table()
 * @ORM\Entity(repositoryClass="Erp\ErpBundle\Entity\ClasseRepository")
 */
class Classe
{
    /**
     * @var integer $id
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var integer $annee_promo
     *
     * @ORM\Column(name="annee_promo", type="integer")
     */
    private $annee_promo;

	/**
     * @var string $section
     *
     * @ORM\Column(name="section", type="string", length=20)
     */
    private $section;
	
	/**
	 * @ORM\OneToMany(targetEntity="Erp\ErpBundle\Entity\Cours", mappedBy="classe")
	 */
	private $cours;
	
    /**
     * Get id
     *
     * @return integer 
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set annee_promo
     *
     * @param integer $anneePromo
     */
    public function setAnneePromo($anneePromo)
    {
        $this->annee_promo = $anneePromo;
    }

    /**
     * Get annee_promo
     *
     * @return integer 
     */
    public function getAnneePromo()
    {
        return $this->annee_promo;
    }
	
	/**
     * Set section
     *
     * @param string $anneePromo
     */
    public function setSection($anneePromo)
    {
        $this->section = $anneePromo;
    }

    /**
     * Get section
     *
     * @return string 
     */
    public function getSection()
    {
        return $this->section;
    }
	
	public function getCours()
	{
		return $this->cours;
	}
	
	public function addCours(\Erp\ErpBundle\Entity\Cours $cours)
	{
		$this->cours[] = $cours;
		$cours->setClasse($this);
	}
}